package com.ease.integration.context.message;

import java.io.Serializable;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlType;

/**
 * 因为jaxb不能处理non-static inner class,所以独立一个类
 * 
 * @author nathanleewei
 * 
 */
@XmlType(propOrder = { "username", "password", "source", "destination", "mock" })
@XmlRootElement(name = "commonRequestHead")
@XmlAccessorType(XmlAccessType.FIELD)
public class CommonRequestHead implements Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	/**
	 * 安全认证的用户名
	 */
	@XmlElement(name = "username")
	private String username;

	/**
	 * 安全认证的密码
	 */
	@XmlElement(name = "password")
	private String password;

	/**
	 * 请求来源
	 */
	@XmlElement(name = "source")
	private String source;

	/**
	 * 请求目的地
	 */
	@XmlElement(name = "destination")
	private String destination;

	/**
	 * 是否模拟请求
	 */
	@XmlElement(name = "mock")
	private boolean mock;

	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public boolean isMock() {
		return mock;
	}

	public void setMock(boolean mock) {
		this.mock = mock;
	}

	public String getSource() {
		return source;
	}

	public void setSource(String source) {
		this.source = source;
	}

	public String getDestination() {
		return destination;
	}

	public void setDestination(String destination) {
		this.destination = destination;
	}
}